Micron Document
Fox's Git Mirrors

Node / acehoss / PyTCP.git / commits / 83e14aa

Commit 83e14aa2ed827a89de9b42e32dc5406ed74e527c


Parents : 3872cee
Author : Sebastian Majewski <ccie18643@gmail.com>
Date : 2022-09-06T08:01:00-05:00

Reformated to 80 columns, phase 1

Changes

4 files changed, 13 insertions(+), 5 deletions(-)


Diff

diff --git a/pytcp/services/udp_daytime.py b/pytcp/services/udp_daytime.py
index fef2d00..63a4e3a 100755
--- a/pytcp/services/udp_daytime.py
+++ b/pytcp/services/udp_daytime.py
@@ -58,7 +58,6 @@ class ServiceUdpDaytime(ServiceUdp):
"""
Inbound connection handler.
"""
-
while True:
_, remote_address = s.recvfrom()
message = bytes(str(datetime.now()), "utf-8")

diff --git a/tests/ether_phtx.py b/tests/ether_phtx.py
index 031d993..03b2a07 100755
--- a/tests/ether_phtx.py
+++ b/tests/ether_phtx.py
@@ -61,7 +61,6 @@ class TestEtherPhtx(TestCase):
Test setup.
"""
super().setUp()
-
self.mns = MockNetworkSettings()
patch_config(self)
setup_mock_packet_handler(self)

diff --git a/tests/packet_flows_rx_tx.py b/tests/packet_flows_rx_tx.py
index 75e840b..c0fb4ac 100755
--- a/tests/packet_flows_rx_tx.py
+++ b/tests/packet_flows_rx_tx.py
@@ -90,7 +90,7 @@ LOCNET_IP4_ADDRESS = Ip4Address("192.168.9.102")
LOCNET_IP6_ADDRESS = Ip6Address("2603:9000:e307:9f09::1fa1")
-class TestPacketHandler(TestCase):
+class TestPacketHandlerRxTx(TestCase):
"""
The RX-TX packet flow integration test class.
"""

diff --git a/tests/udp_phtx.py b/tests/udp_phtx.py
index 95b25cf..fd70b69 100755
--- a/tests/udp_phtx.py
+++ b/tests/udp_phtx.py
@@ -28,6 +28,8 @@
#
# tests/udp_phtx.py - tests specific for UDP phtx module
#
+# ver 2.7
+#
from testslide import TestCase
@@ -44,9 +46,15 @@ TEST_FRAME_DIR = "tests/test_frames/udp_phtx/"
class TestUdpPhtx(TestCase):
+ """
+ UDP packet handler TX unit test class.
+ """
+
def setUp(self):
+ """
+ Set up the test environment.
+ """
super().setUp()
-
self.mns = MockNetworkSettings()
patch_config(self)
setup_mock_packet_handler(self)
@@ -54,7 +62,9 @@ class TestUdpPhtx(TestCase):
# Test name format: 'test_name__test_description__optional_condition'
def test_udp_phtx__ip4_udp_packet(self):
- """Test sending IPv4/UDP packet with no data"""
+ """
+ Test sending the IPv4/UDP packet with no data.
+ """
tx_status = self.packet_handler._phtx_udp(
ip_src=self.mns.stack_ip4_host.address,

Served by rngit 1.4.1 - Generated in 0.07s